package view;

import java.util.Calendar;
import java.util.Date;

import logic.*;

public class Operator {
	
	private CashDesk cashDesk;
	private Calendar calendar;
        private CardDataBase cardDb;
	
	public Operator( CardDataBase cardDataBase ){
            cashDesk = new CashDesk( cardDataBase );
            calendar = Calendar.getInstance();
            cardDb = cardDataBase;
	}
	
	public void operatorSells(){
            
            cashDesk.sellCard(new MetroCardPassLimit(cardDb, CardPassLimit.PASSES5, CardType.STUDENT));
            cashDesk.sellCard(new MetroCardPassLimit(cardDb, CardPassLimit.PASSES10, CardType.STUDENT));
            cashDesk.sellCard(new MetroCardDateLimit(cardDb, CardDaysLimit.DAYS30, CardType.STUDENT));
            cashDesk.sellCard(new MetroCardPassLimit(cardDb, CardPassLimit.PASSES5, CardType.SCHOOL));
            cashDesk.sellCard(new MetroCardPassLimit(cardDb, CardPassLimit.PASSES10, CardType.SCHOOL));
            cashDesk.sellCard(new MetroCardDateLimit(cardDb, CardDaysLimit.DAYS30, CardType.SCHOOL));
            cashDesk.sellCard(new MetroCardPassLimit(cardDb, CardPassLimit.PASSES5, CardType.NORMAL));
            cashDesk.sellCard(new MetroCardPassLimit(cardDb, CardPassLimit.PASSES10, CardType.NORMAL));
            cashDesk.sellCard(new MetroCardDateLimit(cardDb, CardDaysLimit.DAYS10, CardType.NORMAL));
            MetroCard rechargeableCard1 = new MetroCardRechargeable(cardDb);
            cashDesk.sellCard(rechargeableCard1);
            cashDesk.rechargeCard(rechargeableCard1, 20.0);
            rechargeableCard1.addMoney(20.0);
            cashDesk.sellCard( new MetroCardRechargeable(30.0, cardDb));
	}

}
